<?php

namespace App\Library\Requests\Auction;

use App\Library\Requests\Base\BasePageRequest;
use App\Library\Rules\LikeRule;

class AuctionIndexPageRequest extends BasePageRequest
{
    public function rules(): array
    {
        $array = parent::rules();
        return array_merge($array, [
            'title' => ['nullable', 'string', 'max:30', new LikeRule],
            'sort' => 'required|integer|between:0,3',
            'sellerId' => 'nullable|integer|min:1'
        ]);
    }
}
